package com.demo.service.impl;

import com.demo.dao.JingdianDAO;
import com.demo.dao.impl.JingdianDAOImpl;
import com.demo.service.JingdianService;
import com.demo.entity.Jingdian;

import java.io.Serializable;
import java.util.Map;

/**
 * 景点模块的Service层（业务层）的具体实现类，对JingdianService接口中定义的抽象方法作出具体的功能实现
 */
public class JingdianServiceImpl implements JingdianService {
    //@Override
    public void add(Jingdian vo) {
        JingdianDAO jingdianDAO = new JingdianDAOImpl();
        jingdianDAO.add(vo);
    }

    //@Override
    public void delete(long id) {
        JingdianDAO jingdianDAO = new JingdianDAOImpl();
        jingdianDAO.delete(id);
    }

    //@Override
    public void update(Jingdian vo) {
        JingdianDAO jingdianDAO = new JingdianDAOImpl();
        jingdianDAO.update(vo);
    }

    //@Override
    public Jingdian get(Serializable id) {
        JingdianDAO jingdianDAO = new JingdianDAOImpl();
        return jingdianDAO.get(id);
    }

    //@Override
    public Map<String, Object> list(Map<String, Object> params) {
        JingdianDAO jingdianDAO = new JingdianDAOImpl();
        return jingdianDAO.list(params);
    }
}
